import TipBox from './TipBox';

export default {
    install: function (Vue) {
        const Tip = Vue.extend(TipBox);
        const tipFun = function (msg = "默认值", time = 2000) {
            var tip = new Tip({
                data: {
                    msg,
                    time,
                    info: "系统错误，请重试！"
                }
            });
            tip.$mount();
        }
        Vue.prototype.$showTip = tipFun;
        window.showTip = tipFun;

    }
}